<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>

</body>
<script>
    // 命名函数改异步函数
    async function fn() {

    }

    // 匿名函数改异步函数
    var fn = async function () {

    }

    var fn = async () => { }

    var obj = {
        a: 1,
        b: 2,
        sum: async function () {

        },
        async say() {
            console.log(this.a, this.b);
        }
    }

    document.onclick = async function () {

    }

    window.onload = async function () {

    };

    (async function () {

    })();

    (async () => { })()



</script>

</html>